package run.siyuan.jdk.设计模式.工厂模式.工厂模式案例3;

import run.siyuan.jdk.设计模式.工厂模式.工厂模式案例2.HumanFactory;

/**
 * @className: NvWa
 * @Description: TODO 工厂模式-女娲测试
 * @author: siyuan
 * @date: 2022/3/11 6:07 PM
 */
public class NvWa {

    public static void main(String[] args) {
        Human blackHuman = new BlackHumanFactory().createHuman();
        blackHuman.getColor();
        blackHuman.talk();

        Human whiteHuman = new WhiteHumanFactory().createHuman();
        whiteHuman.getColor();
        whiteHuman.talk();

        Human yellowHuman = new YellowHumanFactory().createHuman();
        yellowHuman.getColor();
        yellowHuman.talk();

    }

}
